Containerization technology is becoming popular among developers and information technology administrators. Containers and virtual machines can co-exist as parent-child, as siblings, or as child-parent relationships. With containers hosted on virtual machines (VMs), virtual machines form a ubiquitous and elastic fabric for hosting a container cloud. Application code may then run on a nested virtualization stack, which requires resource optimization and tuning for performance gain in each layer. With containers also capable of migration (live or offline), another level of complexity is added to the optimization problem.
If resources are not correctly allocated, resources in a datacenter may be wasted. As containers are started and shut down on various VMs, some VMs may end up with more resources than necessary for their assigned containers, while other VMs become over-committed, with not enough resources. Resources may therefore be wasted if the containers and VMs are not properly optimized.